import {} from '@/api/trade'

const state = {
    tradeList:[]
}
const mutations = {
    SET_TRADEINFO(state,tradeList){
        state.tradeList = tradeList
    }
}

const actions = {
    async getTradeMarkList({commit}){
        try {
            let result = await getTradmark()
            console.log(result);
            if(result && result.code == 200){
                commit('SET_TRADEINFO', result.data)
                return
            }
            return Promise.reject('获取交易信息失败')
        } catch (error) {
            return Promise.reject(error)
        }
    }
}

const getter = {

}

export default {
    state,
    mutations,
    actions,
    getter
}